using System;
using FireStarter.Base;
using FireStarterModeller.BO;
using Habanero.BO;
using Habanero.BO.ClassDefinition;
using Habanero.BO.Loaders;
using NUnit.Framework;

namespace FireStarter.Test.CodeGeneration
{
    [TestFixture]
    public class TestBase
    {
        protected static string GetRandomString()
        {
            return Guid.NewGuid().ToString("N");
        }

        [TestFixtureSetUp]
        public void Setup()
        {
            ClassDef.ClassDefs.Clear();
            ClassDef.ClassDefs.Add(new XmlClassDefsLoader(BOBroker.GetClassDefsXml(), new DtdLoader()).LoadClassDefs());

            BORegistry.DataAccessor = new DataAccessorInMemory();
        }
    }
}